package com.jt.factory;

import com.jt.service.RemoteProviderService;
import feign.hystrix.FallbackFactory;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.stereotype.Component;

@Component
public class ProviderFallbackFactory implements FallbackFactory<RemoteProviderService> {
    @Override
    public RemoteProviderService create(Throwable throwable) {
        return (msg)->{
            return "服务系统维护中";
        };
    }
}
